local skel = fk.CreateSkill {
  name = "emo__shuijingqiu",
}

skel:addEffect("active", {
  anim_type = "offensive",
  target_num = 1,
  card_num = 0,
  prompt = "#emo__shuijingqiu",
  times = function (self, player)
    return (Fk:currentRoom():getBanner("RoundCount") or 0) - player:usedSkillTimes(skel.name, Player.HistoryPhase)
  end,
  can_use = function (self, player)
    return player:usedSkillTimes(skel.name, Player.HistoryPhase) < (Fk:currentRoom():getBanner("RoundCount") or 0)
  end,
  target_filter = function (self, player, to_select, selected)
    return #selected == 0 and to_select ~= player
  end,
  on_use = function (self, room, effect)
    local player, to = effect.from, effect.tos[1]
    room:damage { from = player, to = to, damage = 1, skillName = skel.name, damageType = fk.CharmDamage }
    if not to.dead then
      to:drawCards(1, skel.name)
    end
  end,
})


Fk:loadTranslationTable{
  ["emo__shuijingqiu"] = "水晶球",
  [":emo__shuijingqiu"] = "出牌阶段限X次，你可以对一名其他角色造成一点法术伤害，并令其摸一张牌（X为当前轮数）。",
  ["#emo__shuijingqiu"] = "对一名其他角色造成一点法术伤害，并令其摸一张牌",
}


return skel
